package tk1.uebung3.restful;

import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.core.MediaType;

import tk1.uebung3.model.ShoppingCart;
import tk1.uebung3.model.ShoppingCartContainer;

@Path("/entershop")
public class EnterShop {

	@GET
	@Produces(MediaType.TEXT_PLAIN)
	public String getNewCartId(){
		
		ShoppingCart shoppingCart = new ShoppingCart();
		ShoppingCartContainer.addShoppingCart(shoppingCart);
		return shoppingCart.getId();
		
	}
}
